<?php

session_start();

// this sets variables in the session 

include_once('config.php');
$productID = $_POST['productID'];
//set BuyCount = coalesce(BuyCount, 0) + 1
echo $productID;
$query="UPDATE `product` SET buyCount=buyCount+1 WHERE id=".$productID;
mysql_query($query);
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
?>
